﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Engine.Voxel
{
    public static class Materials
    {
        static Dictionary<string, IBaseMaterial> mat = new Dictionary<string, IBaseMaterial>(0);
        public static void init()
        {
            IBaseMaterial tmp = new Ground();
            mat.Add(tmp.Name, tmp);
            tmp = new Granit();
            mat.Add(tmp.Name, tmp);
            tmp = new Water();
            mat.Add(tmp.Name, tmp);
        }
        public static IBaseMaterial GetMat(string name)
        {
            return (mat[name]);
        }

        public static void LoadContent(Microsoft.Xna.Framework.Content.ContentManager contentManager)
        {
            foreach (var item in mat)
            {
                item.Value.LoadContent(contentManager);
            }
        }
    }
}
